import http from "@/http/index.js"

export const getList = (params = {}) => {
    return http.get("/user/getList", params).then(res => {
        return res
    })
}

export const createUser = (params = {}) => {
    return http.post("/user/create", params)
}

export const updateUser = (params = {}) => {
    return http.post("/user/update", params)
}

export const detail = (params = {}) => {
    return http.get("/user/detail", {params:{...params}}).then(res => {
        return res.data
    })
}
export const toLogin = (params = {}) => {
    return http.post("/login/toLogin", params).then(res => {
        return res
    })
}